<template>
  <div id="bMap" :style="{
    width:width,
    height:height,
    cLat:{
      type:Object
    },
    cLng:{
      type:Object
    }
  }"></div>
</template>
<script lang="ts" setup>
import {defineEmits, defineProps, ref, reactive, onMounted, toRefs} from 'vue'
import type {PropType} from "vue";
import {MapApi} from "@/utils/typings"
let props = defineProps({
  width: {
    type: [String, Number]
  },
  height: {
    type: [String, Number]
  },
  cLat: {
    type: Number
  },
  cLng: {
    type: Number
  },
  markers: {
    type: [] as PropType<MapApi.Maker[]>,
    required: true
  }
})
let {cLat, cLng, markers} = toRefs(props)
let emits = defineEmits(['onAddress'])


// 暴露方法
defineExpose({ childMethodInit });
</script>
<style scoped>
#bMap {
  width: 100%;
  height: 100%;
}
</style>
